<?php


$_____order_____=file_get_contents("order.json");
$_____order_____=json_decode($_____order_____,1);


$copyorder=file_get_contents("copyorder.json");
if(!empty($copyorder)){
    $copyorder=json_decode($copyorder,1);
    for ($i = 0; $i < count($_____order_____); $i++) {
        array_push($copyorder,$_____order_____[$i]);
    }
}else{
    $copyorder=$_____order_____;
}

// $copyorder_orderno=array_column($copyorder,"order_no");
// $copyorder_orderno_yes__=array_unique($copyorder_orderno);

// $_arr_chong__=[];
// foreach ($copyorder_orderno_yes__ as $key =>$value){
//     for ($i = 0; $i < count($copyorder); $i++) {
//         if($key==$i){
//             $_arr_chong__[]=$copyorder[$i];
//         }
//     }
// }


$copyorder=json_encode($copyorder,JSON_PRETTY_PRINT|JSON_UNESCAPED_UNICODE);
file_put_contents("copyorder.json",$copyorder);